import Vue from 'vue'
import Router from 'vue-router'
// import Filed from '../views/filed/index.vue'
import layout from '../views/layout.vue'
import submitLay from '../views/submitLay.vue'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      component: layout,
      redirect: '/index',
      children: [
        {
          path: 'index',
          name: 'index',
          component: () => import('@/views/home/index')
        },
        {
          path: 'mine',
          name: 'mine',
          component: () => import('@/views/mine/index')
        }
      ]
    },
    {
      path: '/',
      component: submitLay,
      redirect: '/index',
      children: [
        {
          path: 'filed',
          name: 'Filed',
          component: () => import('@/views/filed/index')
        }
      ]
    }
  ]
})
